package diko_parent.eduservice.controller;

import com.diko.commonUtils.R;
import org.springframework.web.bind.annotation.*;

/**
 * @author Emma Li
 * @date 2020/9/18 - 9:09
 */
@CrossOrigin
@RestController
@RequestMapping("/eduservice/user")
public class eduLoginController {
    @PostMapping("login")
    public R login(){
        return R.ok().data("token","admin");
    }

    @GetMapping("info")
    public R info(){
        return R.ok().data("roles","[admin]").data("name","admin").data("avatar","https://emma-photo.oss-cn-shenzhen.aliyuncs.com/photo/01/2020/09/22/c59d424e-c730-42b1-baa3-af25edd410f6.png");
    }
}
